home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.modula2
- Path: cix.compulink.co.uk!usenet
- From: mark_tbu@cix.compulink.co.uk ("Mark Morgan Lloyd ")
- Subject: Re: xor procedure for M-2
- Message-ID: <DnFtME.7GA@cix.compulink.co.uk>
- Organization: KDG Mobrey Telemetry
- References: <francosky.1.1.3132950B@postbox.acs.ohio-state.edu>
- Date: Tue, 27 Feb 1996 14:01:25 GMT
- X-News-Software: Ameol
-
- >
- >
- > if someone could give me a simple way to write a program to
- compute
- > the value
- > of xors in modula2 it would be appreciated.\
- >
- > like a function that returns the decimal value 26 for xor(12, 22)
- > (12 xor 22)
- >
- > later
- > send to emial
- >
-
- <sigh>
-
- Article: 7435 of comp.lang.modula2
- Newsgroups: comp.lang.modula2
- Subject: Re: XOR function
- Organization: KDG Mobrey Telemetry
- References: <1996Feb8.114044.15072@ucl.ac.uk>
- X-News-Software: Ameol
-
- MODULE Demo;
-
- VAR a, b, c: CARDINAL;
-
- BEGIN
- IF SIZE(CARDINAL) <> SIZE(BITSET) THEN (* Paranoid? Me? *)
- UserBreak
- END;
- c:= CARDINAL(BITSET(a) / BITSET(b))
- END Demo.
-
- Mark Morgan Lloyd
- mark_tbu@cix.compulink.co.uk
-
- [Opinions above are the author's, not those of his employers or
- colleagues]
-